package com.es.esjest;

import com.es.esjest.esservice.EsService;
import com.es.esjest.pojo.SearchParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author luheng
 * @create 2019/6/28
 */
@RestController
@RequestMapping("/es")
public class EsController {

    @Autowired
    private EsService service;

    @GetMapping("/search")
    public String search(SearchParam param) {

        return service.search(param);
    }
}
